// ----------------------------------------------------------------------------
// markItUp!
// ----------------------------------------------------------------------------
// Copyright (C) 2008 Jay Salvat
// http://markitup.jaysalvat.com/
// ----------------------------------------------------------------------------
myHtmlSettings = {
    nameSpace:       "html", // Useful to prevent multi-instances CSS conflict
    onShiftEnter:    {keepDefault:false, replaceWith:'<br />\n'},
    onCtrlEnter:     {keepDefault:false, openWith:'\n<p>', closeWith:'</p>\n'},
    onTab:           {keepDefault:false, openWith:'     '},
    markupSet:  [
        {name:'Heading 1', key:'1', openWith:'<h1(!( class="[![Class]!]")!)>', closeWith:'</h1>', placeHolder:'Your title here...' },
        {name:'Heading 2', key:'2', openWith:'<h2(!( class="[![Class]!]")!)>', closeWith:'</h2>', placeHolder:'Your title here...' },
        {name:'Heading 3', key:'3', openWith:'<h3(!( class="[![Class]!]")!)>', closeWith:'</h3>', placeHolder:'Your title here...' },
        {name:'Heading 4', key:'4', openWith:'<h4(!( class="[![Class]!]")!)>', closeWith:'</h4>', placeHolder:'Your title here...' },
        {name:'Heading 5', key:'5', openWith:'<h5(!( class="[![Class]!]")!)>', closeWith:'</h5>', placeHolder:'Your title here...' },
        {name:'Heading 6', key:'6', openWith:'<h6(!( class="[![Class]!]")!)>', closeWith:'</h6>', placeHolder:'Your title here...' },
        {name:'div', openWith:'<div(!( class="[![Class]!]")!)>', closeWith:'</div>'  },
        {name:'Paragraph', openWith:'<p(!( class="[![Class]!]")!)>', closeWith:'</p>'  },
        {name:'Bold', key:'7', openWith:'<b>', closeWith:'</b>' },
        {name:'strong', key:'B', openWith:'<strong>', closeWith:'</strong>' },
        {name:'i', key:'i', openWith:'<i>', closeWith:'</i>' },
        {name:'em', key:'8', openWith:'<em>', closeWith:'</em>' },
        {name:'U', key:'U', openWith:'<u>', closeWith:'</u>'  },
        {name:'span', openWith:'<span(!( class="[![Class]!]")!)>', closeWith:'</span>'  },
        //{separator:'---------------' },
        {name:'class', openWith:'class="', closeWith:'"', placeHolder:'your class' },
        //{separator:'---------------' },
        {name:'id', openWith:'id="', closeWith:'"', placeHolder:'your id' },
        //{separator:'---------------' },
        {name:'Stroke through', key:'s', openWith:'<strike>', closeWith:'</strike>' },
        //{separator:'---------------' },
        {name:'ol', openWith:'<ol>\n\t<li>', closeWith:'<li>\n</ol>' },
        {name:'Ul', openWith:'<ul>\n\t<li>', closeWith:'<li>\n</ul>' },
        {name:'Li', openWith:'\t<li>', closeWith:'</li>' },
        {name:'Picture', key:'P', replaceWith:'<img src="[![Source:!:http://]!]" alt="[![Alternative text]!]" />' },
        {name:'Link', key:'L', openWith:'<a href="[![Link:!:http://]!]"(!( title="[![Title]!]")!)>', closeWith:'</a>', placeHolder:'Your text to link...' },
        //{separator:'---------------'},
        {name:'blockquote', openWith:'<blockquote>', closeWith:'</blockquote>' }, 
        {name:'pre', openWith:'<pre>', closeWith:'</pre>' }, 
        {name:'code', openWith:'<code>', closeWith:'</code>' }, 
        {name:'clear_both', openWith:'<div style="clear:both"></div>\n' }, 
        {name:'hr', openWith:'<hr />' },   
        {name:'br', openWith:'<br />' }, 
        //{separator:'---------------' },
/*        {name:'Clean', replaceWith:function(h) { return h.selection.replace(/<(.*?)>/g, "") } },*/    
        {name:'html', openWith:'<!DOCTYPE HTML>\n<html>\n<head>\n\t<meta  http-equiv="Content-Type" content="text/html;  charset=UTF-8">\n\t<meta http-equiv="X-UA-Compatible"  content="IE=edge,chrome=1">\n\t<title>gubhugreyot - Tutorial Blogger</title>\n<style type="text/css">\n\n</style>\n</head>\n<body>\n\n\n</body>\n</html>'},
        //{separator:'---------------' },
        {name:'style', openWith:'<style type="text/css" media="all">\n\n</style>\n<!-- link css -->\n<link href=".../style.css" rel="stylesheet" type="text/css" />' },
        {name:'script', openWith:'<script type="text/javascript">\n\n</script>\n<!-- link javascript -->\n<script src=".../javascript.js" type="text/javascript"></script>' },
        {name:'Encode \n special chars',
         className:"encodechars", 
         replaceWith:function(markItUp) { 
            c = document.createElement('div');
            c.appendChild(document.createTextNode(markItUp.selection));
            return c.innerHTML; 
         }
        }, 
     {name:'Size', dropMenu :[ 
          {name:'H1', openWith:'<h1>', closeWith:'</h1>', className:"oon1" },
          {name:'H2', openWith:'<h2>', closeWith:'</h2>', className:"oon2" },
          {name:'H3', openWith:'<h3>', closeWith:'</h3>', className:"oon3" },
          {name:'H4', openWith:'<h4>', closeWith:'</h4>', className:"oon4" },
          {name:'H5', openWith:'<h5>', closeWith:'</h5>', className:"oon5" },
          {name:'H6', openWith:'<h6>', closeWith:'</h6>', className:"oon6" }
      ]},
/*      {name:'Colors', openWith:'[color=[![Color]!]]', closeWith:'[/color]', dropMenu: [
          {name:'Yellow', openWith:'[color=yellow]', closeWith:'[/color]', className:"col1-1" },
          {name:'Orange', openWith:'[color=orange]', closeWith:'[/color]', className:"col1-2" },
          {name:'Red', openWith:'[color=red]', closeWith:'[/color]', className:"col1-3" },
          {name:'Blue', openWith:'[color=blue]', closeWith:'[/color]', className:"col2-1" },
          {name:'Purple', openWith:'[color=purple]', closeWith:'[/color]', className:"col2-2" },
          {name:'Green', openWith:'[color=green]', closeWith:'[/color]', className:"col2-3" },
          {name:'White', openWith:'[color=white]', closeWith:'[/color]', className:"col3-1" },
          {name:'Gray', openWith:'[color=gray]', closeWith:'[/color]', className:"col3-2" },
          {name:'<input class="color">', openWith:'<input class="color">' }
      ]},*/

      {name:'Colors', openWith:'[color=[![Color]!]]', closeWith:'[/color]', dropMenu: [
          {name:'Yellow', openWith:'[color=yellow]', closeWith:'[/color]', className:"col1-1" },
          {name:'Orange', openWith:'[color=orange]', closeWith:'[/color]', className:"col1-2" },
          {name:'Red', openWith:'[color=red]', closeWith:'[/color]', className:"col1-3" },
          {name:'Blue', openWith:'[color=blue]', closeWith:'[/color]', className:"col2-1" },
          {name:'Purple', openWith:'[color=purple]', closeWith:'[/color]', className:"col2-2" },
          {name:'Green', openWith:'[color=green]', closeWith:'[/color]', className:"col2-3" },
          {name:'White', openWith:'[color=white]', closeWith:'[/color]', className:"col3-1" },
          {name:'Gray', openWith:'[color=gray]', closeWith:'[/color]', className:"col3-2" },
          {name:'Black', openWith:'[color=black]', closeWith:'[/color]', className:"col3-3" }
      ]},


        {name:'Preview', call:'preview', className:'preview' }
        //{separator:'---------------' }

    ]
}